<ng-template #itemsTpl>
  <ng-container *ngFor="let item of apesDataSource; let index = index">
    <ng-template
      [ngTemplateOutlet]="apesRenderItem"
      [ngTemplateOutletContext]="{ $implicit: item, index: index }"></ng-template>
  </ng-container>
</ng-template>
<div *ngIf="_isHeader" class="{{prefixCls}}-header">
  <ng-container *ngIf="_header; else _headerTpl">{{ _header }}</ng-container>
</div>
<apes-spin [apesSpinning]="apesLoading">
  <div *ngIf="apesLoading && apesDataSource.length === 0" [style.min-height.px]="53"></div>
  <div *ngIf="apesGrid; else itemsTpl" apes-row [apesGutter]="apesGrid.gutter">
    <div apes-col [apesSpan]="apesGrid.span" [apesXs]="apesGrid.xs" [apesSm]="apesGrid.sm" [apesMd]="apesGrid.md" [apesLg]="apesGrid.lg" [apesXl]="apesGrid.xl" [apesXXl]="apesGrid.xxl"
      *ngFor="let item of apesDataSource; let index = index">
      <ng-template
        [ngTemplateOutlet]="apesRenderItem"
        [ngTemplateOutletContext]="{ $implicit: item, index: index }"></ng-template>
    </div>
  </div>
</apes-spin>
<ng-template [ngTemplateOutlet]="apesLoadMore"></ng-template>
<ng-content></ng-content>
<div *ngIf="apesPagination" class="{{prefixCls}}-pagination">
  <ng-template [ngTemplateOutlet]="apesPagination"></ng-template>
</div>
<div *ngIf="_isFooter" class="{{prefixCls}}-footer">
  <ng-container *ngIf="_footer; else _footerTpl">{{ _footer }}</ng-container>
</div>
